<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Eigen: Eigen::GeneralizedEigenSolver&lt; MatrixType_ &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  $(document).ready(function() { init_search(); });
/* @license-end */
</script>
<script type="text/x-mathjax-config">
  MathJax.Hub.Config({
    extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"],
    jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="eigendoxy.css" rel="stylesheet" type="text/css">
<!--  -->
<script type="text/javascript" src="eigen_navtree_hacks.js"></script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="Eigen_Silly_Professor_64x64.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname"><a href="http://eigen.tuxfamily.org">Eigen</a>
   &#160;<span id="projectnumber">3.4.90 (git rev 67eeba6e720c5745abc77ae6c92ce0a44aa7b7ae)</span>
   </div>
  </td>
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.svg"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
          </span>
        </div>
</td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classEigen_1_1GeneralizedEigenSolver.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="classEigen_1_1GeneralizedEigenSolver-members.html">List of all members</a> &#124;
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">Eigen::GeneralizedEigenSolver&lt; MatrixType_ &gt; Class Template Reference<div class="ingroups"><a class="el" href="group__DenseLinearSolvers__chapter.html">Dense linear problems and decompositions</a> &raquo; <a class="el" href="group__DenseLinearSolvers__Reference.html">Reference</a> &raquo; <a class="el" href="group__Eigenvalues__Module.html">Eigenvalues module</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename MatrixType_&gt;<br />
class Eigen::GeneralizedEigenSolver&lt; MatrixType_ &gt;</h3>

<p>Computes the generalized eigenvalues and eigenvectors of a pair of general matrices. </p>
<p>This is defined in the Eigenvalues module.</p><div class="fragment"><div class="line"><span class="preprocessor">#include &lt;Eigen/Eigenvalues&gt;</span> </div>
</div><!-- fragment --><dl class="tparams"><dt>Template Parameters</dt><dd>
  <table class="tparams">
    <tr><td class="paramname">MatrixType_</td><td>the type of the matrices of which we are computing the eigen-decomposition; this is expected to be an instantiation of the <a class="el" href="classEigen_1_1Matrix.html" title="The matrix class, also used for vectors and row-vectors.">Matrix</a> class template. Currently, only real matrices are supported.</td></tr>
  </table>
  </dd>
</dl>
<p>The generalized eigenvalues and eigenvectors of a matrix pair \( A \) and \( B \) are scalars \( \lambda \) and vectors \( v \) such that \( Av = \lambda Bv \). If \( D \) is a diagonal matrix with the eigenvalues on the diagonal, and \( V \) is a matrix with the eigenvectors as its columns, then \( A V = B V D \). The matrix \( V \) is almost always invertible, in which case we have \( A = B V D V^{-1} \). This is called the generalized eigen-decomposition.</p>
<p>The generalized eigenvalues and eigenvectors of a matrix pair may be complex, even when the matrices are real. Moreover, the generalized eigenvalue might be infinite if the matrix B is singular. To workaround this difficulty, the eigenvalues are provided as a pair of complex \( \alpha \) and real \( \beta \) such that: \( \lambda_i = \alpha_i / \beta_i \). If \( \beta_i \) is (nearly) zero, then one can consider the well defined left eigenvalue \( \mu = \beta_i / \alpha_i\) such that: \( \mu_i A v_i = B v_i \), or even \( \mu_i u_i^T A = u_i^T B \) where \( u_i \) is called the left eigenvector.</p>
<p>Call the function <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c" title="Computes generalized eigendecomposition of given matrix.">compute()</a> to compute the generalized eigenvalues and eigenvectors of a given matrix pair. Alternatively, you can use the <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ab17a34ebafee8bf052f55b75f50b96a1" title="Constructor; computes the generalized eigendecomposition of given matrix pair.">GeneralizedEigenSolver(const MatrixType&amp;, const MatrixType&amp;, bool)</a> constructor which computes the eigenvalues and eigenvectors at construction time. Once the eigenvalue and eigenvectors are computed, they can be retrieved with the <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d" title="Returns an expression of the computed generalized eigenvalues.">eigenvalues()</a> and eigenvectors() functions.</p>
<p>Here is an usage example of this class: Example: </p><div class="fragment"><div class="line">GeneralizedEigenSolver&lt;MatrixXf&gt; ges;</div>
<div class="line"><a class="code" href="group__matrixtypedefs.html#ga731599f782380312960376c43450eb48">MatrixXf</a> A = <a class="code" href="classEigen_1_1DenseBase.html#ae814abb451b48ed872819192dc188c19">MatrixXf::Random</a>(4,4);</div>
<div class="line"><a class="code" href="group__matrixtypedefs.html#ga731599f782380312960376c43450eb48">MatrixXf</a> B = <a class="code" href="classEigen_1_1DenseBase.html#ae814abb451b48ed872819192dc188c19">MatrixXf::Random</a>(4,4);</div>
<div class="line">ges.compute(A, B);</div>
<div class="line">cout &lt;&lt; <span class="stringliteral">&quot;The (complex) numerators of the generalzied eigenvalues are: &quot;</span> &lt;&lt; ges.alphas().transpose() &lt;&lt; endl;</div>
<div class="line">cout &lt;&lt; <span class="stringliteral">&quot;The (real) denominatore of the generalzied eigenvalues are: &quot;</span> &lt;&lt; ges.betas().transpose() &lt;&lt; endl;</div>
<div class="line">cout &lt;&lt; <span class="stringliteral">&quot;The (complex) generalzied eigenvalues are (alphas./beta): &quot;</span> &lt;&lt; ges.eigenvalues().transpose() &lt;&lt; endl;</div>
<div class="ttc" id="aclassEigen_1_1DenseBase_html_ae814abb451b48ed872819192dc188c19"><div class="ttname"><a href="classEigen_1_1DenseBase.html#ae814abb451b48ed872819192dc188c19">Eigen::DenseBase::Random</a></div><div class="ttdeci">static const RandomReturnType Random()</div><div class="ttdef"><b>Definition:</b> Random.h:114</div></div>
<div class="ttc" id="agroup__matrixtypedefs_html_ga731599f782380312960376c43450eb48"><div class="ttname"><a href="group__matrixtypedefs.html#ga731599f782380312960376c43450eb48">Eigen::MatrixXf</a></div><div class="ttdeci">Matrix&lt; float, Dynamic, Dynamic &gt; MatrixXf</div><div class="ttdoc">Dynamic×Dynamic matrix of type float.</div><div class="ttdef"><b>Definition:</b> Matrix.h:500</div></div>
</div><!-- fragment --><p> Output: </p><pre class="fragment">The (complex) numerators of the generalzied eigenvalues are:  (-0.126,0.569) (-0.126,-0.569)      (-0.398,0)       (-1.12,0)
The (real) denominatore of the generalzied eigenvalues are: -1.56 -1.56 -1.25 0.746
The (complex) generalzied eigenvalues are (alphas./beta): (0.081,-0.365)  (0.081,0.365)     (0.318,-0)       (-1.5,0)
</pre><dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1MatrixBase.html#a30430fa3d5b4e74d312fd4f502ac984d" title="Computes the eigenvalues of a matrix.">MatrixBase::eigenvalues()</a>, class <a class="el" href="classEigen_1_1ComplexEigenSolver.html" title="Computes eigenvalues and eigenvectors of general complex matrices.">ComplexEigenSolver</a>, class <a class="el" href="classEigen_1_1SelfAdjointEigenSolver.html" title="Computes eigenvalues and eigenvectors of selfadjoint matrices.">SelfAdjointEigenSolver</a> </dd></dl>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a4f7fcede2f4a9b2035cd085699312ea8"><td class="memItemLeft" align="right" valign="top">typedef std::complex&lt; RealScalar &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a></td></tr>
<tr class="memdesc:a4f7fcede2f4a9b2035cd085699312ea8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Complex scalar type for <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>.  <a href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">More...</a><br /></td></tr>
<tr class="separator:a4f7fcede2f4a9b2035cd085699312ea8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a653a8eb657e8e81a1addf236c8ac6fad"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a>, ColsAtCompileTime, 1, Options &amp;~<a class="el" href="group__enums.html#ggaacded1a18ae58b0f554751f6cdf9eb13a77c993a8d9f6efe5c1159fb2ab07dd4f">RowMajor</a>, MaxColsAtCompileTime, 1 &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">ComplexVectorType</a></td></tr>
<tr class="memdesc:a653a8eb657e8e81a1addf236c8ac6fad"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type for vector of complex scalar values eigenvalues as returned by <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas()</a>.  <a href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">More...</a><br /></td></tr>
<tr class="separator:a653a8eb657e8e81a1addf236c8ac6fad"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6c19ca74db8d5ee313db46748982299a"><td class="memItemLeft" align="right" valign="top"><a id="a6c19ca74db8d5ee313db46748982299a"></a>
typedef <a class="el" href="classEigen_1_1CwiseBinaryOp.html">CwiseBinaryOp</a>&lt; internal::scalar_quotient_op&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a>, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98">Scalar</a> &gt;, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">ComplexVectorType</a>, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">VectorType</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6c19ca74db8d5ee313db46748982299a">EigenvalueType</a></td></tr>
<tr class="memdesc:a6c19ca74db8d5ee313db46748982299a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Expression type for the eigenvalues as returned by <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d" title="Returns an expression of the computed generalized eigenvalues.">eigenvalues()</a>. <br /></td></tr>
<tr class="separator:a6c19ca74db8d5ee313db46748982299a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aea30f692795a188034454342519419bb"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a>, RowsAtCompileTime, ColsAtCompileTime, Options, MaxRowsAtCompileTime, MaxColsAtCompileTime &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aea30f692795a188034454342519419bb">EigenvectorsType</a></td></tr>
<tr class="memdesc:aea30f692795a188034454342519419bb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type for matrix of eigenvectors as returned by eigenvectors().  <a href="classEigen_1_1GeneralizedEigenSolver.html#aea30f692795a188034454342519419bb">More...</a><br /></td></tr>
<tr class="separator:aea30f692795a188034454342519419bb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa41eaf99a4e965cf7b9d3dd3a4756405"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Eigen::Index</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a></td></tr>
<tr class="separator:aa41eaf99a4e965cf7b9d3dd3a4756405"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afca25f62cd5913edce7b6b1f2f01aea6"><td class="memItemLeft" align="right" valign="top"><a id="afca25f62cd5913edce7b6b1f2f01aea6"></a>
typedef MatrixType_&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a></td></tr>
<tr class="memdesc:afca25f62cd5913edce7b6b1f2f01aea6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Synonym for the template parameter <code>MatrixType_</code>. <br /></td></tr>
<tr class="separator:afca25f62cd5913edce7b6b1f2f01aea6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a81b71b590b3a2bbb84fb3aebf3cd2f98"><td class="memItemLeft" align="right" valign="top"><a id="a81b71b590b3a2bbb84fb3aebf3cd2f98"></a>
typedef MatrixType::Scalar&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98">Scalar</a></td></tr>
<tr class="memdesc:a81b71b590b3a2bbb84fb3aebf3cd2f98"><td class="mdescLeft">&#160;</td><td class="mdescRight">Scalar type for matrices of type <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>. <br /></td></tr>
<tr class="separator:a81b71b590b3a2bbb84fb3aebf3cd2f98"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a69344c66c55a1e104b4d42c39e50d9de"><td class="memItemLeft" align="right" valign="top">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98">Scalar</a>, ColsAtCompileTime, 1, Options &amp;~<a class="el" href="group__enums.html#ggaacded1a18ae58b0f554751f6cdf9eb13a77c993a8d9f6efe5c1159fb2ab07dd4f">RowMajor</a>, MaxColsAtCompileTime, 1 &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">VectorType</a></td></tr>
<tr class="memdesc:a69344c66c55a1e104b4d42c39e50d9de"><td class="mdescLeft">&#160;</td><td class="mdescRight">Type for vector of real scalar values eigenvalues as returned by <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas()</a>.  <a href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">More...</a><br /></td></tr>
<tr class="separator:a69344c66c55a1e104b4d42c39e50d9de"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:aaf085ff23129173015f1c52d3b696623"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">ComplexVectorType</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas</a> () const</td></tr>
<tr class="separator:aaf085ff23129173015f1c52d3b696623"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6bd873cd26af5fbea5f8757e23f64616"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">VectorType</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas</a> () const</td></tr>
<tr class="separator:a6bd873cd26af5fbea5f8757e23f64616"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a275910b47dfe5f40211dcb59cfd68f3c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c">compute</a> (const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;A, const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;B, bool computeEigenvectors=true)</td></tr>
<tr class="memdesc:a275910b47dfe5f40211dcb59cfd68f3c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Computes generalized eigendecomposition of given matrix.  <a href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c">More...</a><br /></td></tr>
<tr class="separator:a275910b47dfe5f40211dcb59cfd68f3c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac0544a47c14e611888496169fe097c1d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6c19ca74db8d5ee313db46748982299a">EigenvalueType</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d">eigenvalues</a> () const</td></tr>
<tr class="memdesc:ac0544a47c14e611888496169fe097c1d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns an expression of the computed generalized eigenvalues.  <a href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d">More...</a><br /></td></tr>
<tr class="separator:ac0544a47c14e611888496169fe097c1d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a88b523545b3e852942f8f7c3f4996592"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a88b523545b3e852942f8f7c3f4996592">GeneralizedEigenSolver</a> ()</td></tr>
<tr class="memdesc:a88b523545b3e852942f8f7c3f4996592"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor.  <a href="classEigen_1_1GeneralizedEigenSolver.html#a88b523545b3e852942f8f7c3f4996592">More...</a><br /></td></tr>
<tr class="separator:a88b523545b3e852942f8f7c3f4996592"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab17a34ebafee8bf052f55b75f50b96a1"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ab17a34ebafee8bf052f55b75f50b96a1">GeneralizedEigenSolver</a> (const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;A, const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;B, bool computeEigenvectors=true)</td></tr>
<tr class="memdesc:ab17a34ebafee8bf052f55b75f50b96a1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructor; computes the generalized eigendecomposition of given matrix pair.  <a href="classEigen_1_1GeneralizedEigenSolver.html#ab17a34ebafee8bf052f55b75f50b96a1">More...</a><br /></td></tr>
<tr class="separator:ab17a34ebafee8bf052f55b75f50b96a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acd9f42ef54df1823adb05e9330888e5f"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#acd9f42ef54df1823adb05e9330888e5f">GeneralizedEigenSolver</a> (<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a> size)</td></tr>
<tr class="memdesc:acd9f42ef54df1823adb05e9330888e5f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor with memory preallocation.  <a href="classEigen_1_1GeneralizedEigenSolver.html#acd9f42ef54df1823adb05e9330888e5f">More...</a><br /></td></tr>
<tr class="separator:acd9f42ef54df1823adb05e9330888e5f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a472d06a8fa39dfef82c966a3840141f1"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a472d06a8fa39dfef82c966a3840141f1">setMaxIterations</a> (<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a> maxIters)</td></tr>
<tr class="separator:a472d06a8fa39dfef82c966a3840141f1"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Member Typedef Documentation</h2>
<a id="a4f7fcede2f4a9b2035cd085699312ea8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4f7fcede2f4a9b2035cd085699312ea8">&#9670;&nbsp;</a></span>ComplexScalar</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef std::complex&lt;RealScalar&gt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Complex scalar type for <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>. </p>
<p>This is <code>std::complex&lt;Scalar&gt;</code> if <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98" title="Scalar type for matrices of type MatrixType.">Scalar</a> is real (e.g., <code>float</code> or <code>double</code>) and just <code>Scalar</code> if <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98" title="Scalar type for matrices of type MatrixType.">Scalar</a> is complex. </p>

</div>
</div>
<a id="a653a8eb657e8e81a1addf236c8ac6fad"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a653a8eb657e8e81a1addf236c8ac6fad">&#9670;&nbsp;</a></span>ComplexVectorType</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt;<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a>, ColsAtCompileTime, 1, Options &amp; ~<a class="el" href="group__enums.html#ggaacded1a18ae58b0f554751f6cdf9eb13a77c993a8d9f6efe5c1159fb2ab07dd4f">RowMajor</a>, MaxColsAtCompileTime, 1&gt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">ComplexVectorType</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Type for vector of complex scalar values eigenvalues as returned by <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas()</a>. </p>
<p>This is a column vector with entries of type <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8" title="Complex scalar type for MatrixType.">ComplexScalar</a>. The length of the vector is the size of <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>. </p>

</div>
</div>
<a id="aea30f692795a188034454342519419bb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aea30f692795a188034454342519419bb">&#9670;&nbsp;</a></span>EigenvectorsType</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt;<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8">ComplexScalar</a>, RowsAtCompileTime, ColsAtCompileTime, Options, MaxRowsAtCompileTime, MaxColsAtCompileTime&gt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aea30f692795a188034454342519419bb">EigenvectorsType</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Type for matrix of eigenvectors as returned by eigenvectors(). </p>
<p>This is a square matrix with entries of type <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a4f7fcede2f4a9b2035cd085699312ea8" title="Complex scalar type for MatrixType.">ComplexScalar</a>. The size is the same as the size of <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>. </p>

</div>
</div>
<a id="aa41eaf99a4e965cf7b9d3dd3a4756405"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa41eaf99a4e965cf7b9d3dd3a4756405">&#9670;&nbsp;</a></span>Index</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="namespaceEigen.html#a62e77e0933482dafde8fe197d9a2cfde">Eigen::Index</a> <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000015">Deprecated:</a></b></dt><dd>since <a class="el" href="namespaceEigen.html" title="Namespace containing all symbols from the Eigen library.">Eigen</a> 3.3 </dd></dl>

</div>
</div>
<a id="a69344c66c55a1e104b4d42c39e50d9de"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a69344c66c55a1e104b4d42c39e50d9de">&#9670;&nbsp;</a></span>VectorType</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">typedef <a class="el" href="classEigen_1_1Matrix.html">Matrix</a>&lt;<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98">Scalar</a>, ColsAtCompileTime, 1, Options &amp; ~<a class="el" href="group__enums.html#ggaacded1a18ae58b0f554751f6cdf9eb13a77c993a8d9f6efe5c1159fb2ab07dd4f">RowMajor</a>, MaxColsAtCompileTime, 1&gt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">VectorType</a></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Type for vector of real scalar values eigenvalues as returned by <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas()</a>. </p>
<p>This is a column vector with entries of type <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a81b71b590b3a2bbb84fb3aebf3cd2f98" title="Scalar type for matrices of type MatrixType.">Scalar</a>. The length of the vector is the size of <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6" title="Synonym for the template parameter MatrixType_.">MatrixType</a>. </p>

</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a88b523545b3e852942f8f7c3f4996592"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a88b523545b3e852942f8f7c3f4996592">&#9670;&nbsp;</a></span>GeneralizedEigenSolver() <span class="overload">[1/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Default constructor. </p>
<p>The default constructor is useful in cases in which the user intends to perform decompositions via EigenSolver::compute(const MatrixType&amp;, bool).</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c" title="Computes generalized eigendecomposition of given matrix.">compute()</a> for an example. </dd></dl>

</div>
</div>
<a id="acd9f42ef54df1823adb05e9330888e5f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acd9f42ef54df1823adb05e9330888e5f">&#9670;&nbsp;</a></span>GeneralizedEigenSolver() <span class="overload">[2/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a> </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a>&#160;</td>
          <td class="paramname"><em>size</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">explicit</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Default constructor with memory preallocation. </p>
<p>Like the default constructor but with preallocation of the internal data according to the specified problem <em>size</em>. </p><dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a88b523545b3e852942f8f7c3f4996592" title="Default constructor.">GeneralizedEigenSolver()</a> </dd></dl>

</div>
</div>
<a id="ab17a34ebafee8bf052f55b75f50b96a1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab17a34ebafee8bf052f55b75f50b96a1">&#9670;&nbsp;</a></span>GeneralizedEigenSolver() <span class="overload">[3/3]</span></h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::<a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a> </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;&#160;</td>
          <td class="paramname"><em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;&#160;</td>
          <td class="paramname"><em>B</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>computeEigenvectors</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Constructor; computes the generalized eigendecomposition of given matrix pair. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">A</td><td>Square matrix whose eigendecomposition is to be computed. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">B</td><td>Square matrix whose eigendecomposition is to be computed. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">computeEigenvectors</td><td>If true, both the eigenvectors and the eigenvalues are computed; if false, only the eigenvalues are computed.</td></tr>
  </table>
  </dd>
</dl>
<p>This constructor calls <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c" title="Computes generalized eigendecomposition of given matrix.">compute()</a> to compute the generalized eigenvalues and eigenvectors.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c" title="Computes generalized eigendecomposition of given matrix.">compute()</a> </dd></dl>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="aaf085ff23129173015f1c52d3b696623"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aaf085ff23129173015f1c52d3b696623">&#9670;&nbsp;</a></span>alphas()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a653a8eb657e8e81a1addf236c8ac6fad">ComplexVectorType</a>&amp; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::alphas </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>A const reference to the vectors containing the alpha values</dd></dl>
<p>This vector permits to reconstruct the j-th eigenvalues as alphas(i)/betas(j).</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas()</a>, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d" title="Returns an expression of the computed generalized eigenvalues.">eigenvalues()</a> </dd></dl>

</div>
</div>
<a id="a6bd873cd26af5fbea5f8757e23f64616"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6bd873cd26af5fbea5f8757e23f64616">&#9670;&nbsp;</a></span>betas()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a69344c66c55a1e104b4d42c39e50d9de">VectorType</a>&amp; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::betas </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<dl class="section return"><dt>Returns</dt><dd>A const reference to the vectors containing the beta values</dd></dl>
<p>This vector permits to reconstruct the j-th eigenvalues as alphas(i)/betas(j).</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas()</a>, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d" title="Returns an expression of the computed generalized eigenvalues.">eigenvalues()</a> </dd></dl>

</div>
</div>
<a id="a275910b47dfe5f40211dcb59cfd68f3c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a275910b47dfe5f40211dcb59cfd68f3c">&#9670;&nbsp;</a></span>compute()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a>&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &gt; &amp; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &gt;::compute </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;&#160;</td>
          <td class="paramname"><em>A</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#afca25f62cd5913edce7b6b1f2f01aea6">MatrixType</a> &amp;&#160;</td>
          <td class="paramname"><em>B</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>computeEigenvectors</em> = <code>true</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Computes generalized eigendecomposition of given matrix. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">A</td><td>Square matrix whose eigendecomposition is to be computed. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">B</td><td>Square matrix whose eigendecomposition is to be computed. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">computeEigenvectors</td><td>If true, both the eigenvectors and the eigenvalues are computed; if false, only the eigenvalues are computed. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Reference to <code>*this</code> </dd></dl>
<p>This function computes the eigenvalues of the real matrix <code>matrix</code>. The <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ac0544a47c14e611888496169fe097c1d" title="Returns an expression of the computed generalized eigenvalues.">eigenvalues()</a> function can be used to retrieve them. If <code>computeEigenvectors</code> is true, then the eigenvectors are also computed and can be retrieved by calling eigenvectors().</p>
<p>The matrix is first reduced to real generalized Schur form using the <a class="el" href="classEigen_1_1RealQZ.html" title="Performs a real QZ decomposition of a pair of square matrices.">RealQZ</a> class. The generalized Schur decomposition is then used to compute the eigenvalues and eigenvectors.</p>
<p>The cost of the computation is dominated by the cost of the generalized Schur decomposition.</p>
<p>This method reuses of the allocated data in the <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html" title="Computes the generalized eigenvalues and eigenvectors of a pair of general matrices.">GeneralizedEigenSolver</a> object. </p>

</div>
</div>
<a id="ac0544a47c14e611888496169fe097c1d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac0544a47c14e611888496169fe097c1d">&#9670;&nbsp;</a></span>eigenvalues()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6c19ca74db8d5ee313db46748982299a">EigenvalueType</a> <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::eigenvalues </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Returns an expression of the computed generalized eigenvalues. </p>
<dl class="section return"><dt>Returns</dt><dd>An expression of the column vector containing the eigenvalues.</dd></dl>
<p>It is a shortcut for</p><div class="fragment"><div class="line">this-&gt;<a class="code" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas</a>().cwiseQuotient(this-&gt;<a class="code" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas</a>()); </div>
<div class="ttc" id="aclassEigen_1_1GeneralizedEigenSolver_html_a6bd873cd26af5fbea5f8757e23f64616"><div class="ttname"><a href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">Eigen::GeneralizedEigenSolver::betas</a></div><div class="ttdeci">const VectorType &amp; betas() const</div><div class="ttdef"><b>Definition:</b> GeneralizedEigenSolver.h:226</div></div>
<div class="ttc" id="aclassEigen_1_1GeneralizedEigenSolver_html_aaf085ff23129173015f1c52d3b696623"><div class="ttname"><a href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">Eigen::GeneralizedEigenSolver::alphas</a></div><div class="ttdeci">const ComplexVectorType &amp; alphas() const</div><div class="ttdef"><b>Definition:</b> GeneralizedEigenSolver.h:215</div></div>
</div><!-- fragment --><p> Not that betas might contain zeros. It is therefore not recommended to use this function, but rather directly deal with the alphas and betas vectors.</p>
<dl class="section pre"><dt>Precondition</dt><dd>Either the constructor <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#ab17a34ebafee8bf052f55b75f50b96a1" title="Constructor; computes the generalized eigendecomposition of given matrix pair.">GeneralizedEigenSolver(const MatrixType&amp;,const MatrixType&amp;,bool)</a> or the member function <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a275910b47dfe5f40211dcb59cfd68f3c" title="Computes generalized eigendecomposition of given matrix.">compute(const MatrixType&amp;,const MatrixType&amp;,bool)</a> has been called before.</dd></dl>
<p>The eigenvalues are repeated according to their algebraic multiplicity, so there are as many eigenvalues as rows in the matrix. The eigenvalues are not sorted in any particular order.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aaf085ff23129173015f1c52d3b696623">alphas()</a>, <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#a6bd873cd26af5fbea5f8757e23f64616">betas()</a>, eigenvectors() </dd></dl>

</div>
</div>
<a id="a472d06a8fa39dfef82c966a3840141f1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a472d06a8fa39dfef82c966a3840141f1">&#9670;&nbsp;</a></span>setMaxIterations()</h2>

<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename MatrixType_ &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a>&amp; <a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">Eigen::GeneralizedEigenSolver</a>&lt; MatrixType_ &gt;::setMaxIterations </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html#aa41eaf99a4e965cf7b9d3dd3a4756405">Index</a>&#160;</td>
          <td class="paramname"><em>maxIters</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>Sets the maximal number of iterations allowed. </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="GeneralizedEigenSolver_8h_source.html">GeneralizedEigenSolver.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespaceEigen.html">Eigen</a></li><li class="navelem"><a class="el" href="classEigen_1_1GeneralizedEigenSolver.html">GeneralizedEigenSolver</a></li>
    <li class="footer">Generated on Thu Apr 21 2022 13:07:55 for Eigen by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.9.1 </li>
  </ul>
</div>
</body>
</html>
